package com.polytech.ihm;

import java.awt.FlowLayout;
import java.util.Date;

import javax.swing.BoxLayout;
import javax.swing.JLabel;
import javax.swing.JPanel;

import com.toedter.calendar.JCalendar;

public class LabeledCalender  extends JPanel{
	
	private JCalendar date=new JCalendar();
	private JLabel label=new JLabel();
	private JPanel panel=new JPanel();
	public LabeledCalender(String label) {
		this.label.setText(label);
		panel.setLayout(new BoxLayout(panel, BoxLayout.Y_AXIS));
		panel.add(this.label);
		panel.add(date);
		this.setLayout(new FlowLayout(FlowLayout.LEFT));
		this.add(panel);
		
	}
	
	public Date getDate(){
		return this.date.getDate();
	}

}
